package com.wson.adapter.codisk;

import java.io.InputStream;
import java.util.List;

import com.wson.adapter.oauth.IOAuthAdapter;
import com.wson.model.clouddisk.file.ICodiskFileView;

public interface ICodiskAdapter extends IOAuthAdapter{
	//百度
	//http://developer.baidu.com/wiki/index.php?title=%E5%B8%AE%E5%8A%A9%E6%96%87%E6%A1%A3%E9%A6%96%E9%A1%B5/%E4%B8%AA%E4%BA%BA%E4%BA%91%E5%AD%98%E5%82%A8API/api%E6%8E%A5%E5%8F%A3%E6%96%87%E6%A1%A3
	
	//快盘
	//http://www.kuaipan.cn/developers/document_apishare.htm
	

	
	public ICodiskFileView mkdir(String directory)throws Exception;
	
	public ICodiskFileView upload(ICodiskFileView file)throws Exception;
	
	public ICodiskFileView upload(String path, InputStream is, long size)throws Exception;
	
	public ICodiskFileView uploadshare(String path, InputStream is, long size)throws Exception;
	
	public String share(String path)throws Exception;
	
	public void copydir(String directorysrc, String directorydest)throws Exception;
	
	public void movedir(String directorysrc, String directorydest)throws Exception;
	
	public ICodiskFileView filemeta(String fileid)throws Exception;
	
	//public ICodiskDirectoryView dirmeta(String directoryid)throws Exception;
	
	public List<ICodiskFileView> listfiles(String directory)throws Exception;
	
	public ICodiskFileView download(String fileid)throws Exception;
	
	public void deletefile(String fileid)throws Exception;
	
	public void deletedir(String dirid)throws Exception;	
	
	public String retrieveProvisionUrl(ICodiskFileView dir)throws Exception;
	
	
/*	public String getAccessToken();
	public void setAccessToken(String accessToken);
	public String getAccessSecret();
	public void setAccessSecret(String accessSecret) ;*/
	
}
